#define _CRT_SECURE_NO_WARNINGS 1

class Solution {
public:

    bool isPalindrome(string s)
    {

        string s1;

        for (int i = 0; i < s.size(); i++)
        {
            if ((s[i] >= 'a' && s[i] <= 'z') || (s[i] >= '0') && s[i] <= '9')
            {
                s1 += s[i];
            }
            else if (s[i] >= 'A' && s[i] <= 'Z')
            {
                s1 += (s[i] + 32);
            }
        }

        cout << s1 << endl;
        int left = 0;
        int right = s1.size() - 1;

        while (left <= right)
        {
            if (s1[left] != s1[right])
            {
                return false;
            }

            left++;
            right--;
        }

        return true;

    }
};